﻿using System;
using System.Net;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Documents;
using System.Windows.Ink;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Animation;
using System.Windows.Shapes;
using PatternWell.PAC;

namespace $safeprojectname$.DataModel.View
{
    /// <summary>
    /// View model implementation for 'MainViewModel'
    /// </summary>
    public partial class MainViewModel : NotificationBase, IViewModel
    {
        #region Dispose Implementation - Implementation of the disposal helper method (Do not modify)

        /// <summary>
        /// Helper method that releases resources for this class implementation.
        /// </summary>
        /// <param name="disposed">flag that determines if the class has already been disposed.</param>
        protected override void Dispose(bool disposed)
        {
            ReleaseResourcesForMainViewModel();
            base.Dispose(disposed);
        }

        #endregion

        #region Release Management - Logic used to release resources for this class (Add release logic in the supplied helper methods)

        /// <summary>
        /// Helper method that releases resource for the 'MainViewModel' class.
        /// </summary>
        private void ReleaseResourcesForMainViewModel()
        {
            //Releasing the view date property
            //I cleare the type through the setter, this is to make sure that databinding clears the reference from the subscribing silverlight consumer.
            ViewDate = null;
        }

        #endregion

        #region Property - ViewDate

        /// <summary>
        /// Field that backs the property 'ViewDate'
        /// </summary>
        private string _viewDate = null;

        /// <summary>
        /// Constant that stores the name of property 'ViewDate'
        /// </summary>
        public const string PropertyNameViewDate = "ViewDate";

        /// <summary>
        /// The current date
        /// </summary>
        /// <remarks>
        /// This property supports property changed notification.
        /// </remarks>
        public string ViewDate
        {
            get { return _viewDate; }

            set
            {
                _viewDate = value;
                OnPropertyChanged(this, new System.ComponentModel.PropertyChangedEventArgs(PropertyNameViewDate));
            }
        }

        #endregion



        

    }
}
